/*
 * To change this template, choose Tools | Templates
 * and open the template in the editor.
 */
package Model;

import Controller.DefaultController;

/**
 *
 * @author mvinicio
 */
public class Character extends AbstractModel {
    
    private String path;
    private int x;
    private int y;

    public void init(String path, int x, int y) {

        setPath(path);
        setX(x);
        setY(y);
    }
    
    public String getPath() {
        return path;
    }

    public void setPath(String path) {
        String oldPath = this.path;
        this.path = path;

        firePropertyChange(
            DefaultController.characterPath,
            oldPath, path);
    }

    public int getX() {
        return x;
    }

    public void setX(int x) {
        int oldX = this.x;
        this.x = x;

        firePropertyChange(
            DefaultController.characterX,
            oldX, x);
    }

    public int getY() {
        return y;
    }

    public void setY(int y) {
        int oldY = this.y;
        this.y = y;

        firePropertyChange(
            DefaultController.characterY,
            oldY, y);
    }
}
